function handles = resetAnalysis(mode, handles)
% resetAnalysis
%
% Editing:
% gs may 2005
% ----------------------------------------------------

switch mode
    case 'load'
        % reset on loading
        handles.data.map = [];
        handles.data.acq = [];
        handles.data.acq.avgLaserIntensity = [];
    case 'reanalyze'
    otherwise
end

% reset cell parameters
handles.data.map.mapAvg.rseries = [];
handles.data.map.mapAvg.rmembrane = [];
handles.data.map.mapAvg.cmembrane = [];

% reset baseline analysis results
handles.data.map.mapAvg.synThreshpAmV = [];
handles.data.map.mapAvg.baselineSD = [];
handles.data.map.mapAvg.spontEventRate = [];
